package com.youlu.campus.entity;

import com.youlu.campus.base.user.UserBase;
import lombok.Data;
import org.springframework.data.annotation.Transient;
import org.springframework.data.mongodb.core.index.IndexDirection;
import org.springframework.data.mongodb.core.index.Indexed;
import org.springframework.data.mongodb.core.mapping.Document;

import java.util.Date;
import java.util.Set;

/**
 * C端用户信息实体类
 *
 * @author: zgz
 * @date: 2020/11/10 15:28
 */
@Data
@Document("user_info")
public class UserPO extends UserBase {
    /**
     * 会员卡编号
     */
    @Indexed
    private String memberShipInfoId;

    /**
     * 是否会员.是否会员
     */
    private Boolean memberShiped;
    /**
     * 是否失效
     */
    private Date expiredTime;
    /**
     * 剩余次数
     */
    private Integer remainedNum;
    /**
     * 是否授权
     */
    private Boolean binded = Boolean.FALSE;
    /**
     * 当前平台
     */
    private String currentPlatform;
    /**
     * 是否验证手机号
     */
    @Indexed
    private Boolean checkedMobile = Boolean.FALSE;
    /**
     * 绑定手机号时间
     */
    @Indexed(direction = IndexDirection.ASCENDING)
    protected Date checkedMobileTime;
    /**
     * 排行榜头像
     */
    protected String rankAvatarUrl;
    /**
     * 排行榜昵称
     */
    protected String rankNickName;

    @Transient
    private Boolean signUpVideo = Boolean.FALSE;

    /**
     * 是否h5答题报名-用于报名信息写入扩展表
     */
    @Transient
    private Boolean h5SignUp = Boolean.FALSE;
    @Transient
    private String receiveName;
    @Transient
    private String receiveMobile;

    private String majorId;

    private String majorName;

    private String enName;

    /**
     * 订单查询-小程序
     */
    private Set<String> mobileSet;

    /**
     * 账户列表ID
     */
    private Set<String> accountInfoIdList;

    /**
     * 活动渠道
     */
    @Transient
    private String activityChannelId;

    /**
     * 微信小程序openId
     */
    private String miniOpenId;
}
